home *** CD-ROM | disk | FTP | other *** search
- on InitSection Num
- global gUserData, gSectNum, gRewardMovie, gSectData, wordlist, gInPuzzle
- set gInPuzzle to 1
- set gSectNum to CalcSectData(Num)
- set lSectCfg to RetConfig(Num)
- set audioclip to GetSectAudio(lSectCfg)
- set gRewardMovie to GetSectReward(lSectCfg)
- set wordlist to GetSectList(lSectCfg)
- set lMovieName to GetSectName(lSectCfg)
- if length(audioclip) >= 1 then
- PlayAudio(audioclip)
- holdSound()
- end if
- set gSectData to GetUserData(gSectNum)
- return lMovieName
- end
-
- on resetPuzzle
- global gLow, gSectData
- set lCount to the number of items in gSectData
- repeat with t = 1 to lCount
- if item t of gSectData = 1 then
- set spritenum to t + gLow - 1
- Swap2ONstate(spritenum)
- end if
- end repeat
- updateStage()
- end
-
- on Swap2ONstate pSpriteNum
- set castnumber to the castNum of sprite pSpriteNum
- set castname to the name of cast castnumber & ".on"
- SwapSprite(pSpriteNum, castname)
- end
-